<#assign contextPath=springMacroRequestContext.getContextPath() />
<#import "/public/frame/main.html" as frame />
<@frame.head "南航明珠商城-商品列表">
</@frame.head>
<link rel="stylesheet" type="text/css" href="${contextPath}/resources/css/search_table.css" />
<nav class="breadcrumb"><i class="Hui-iconfont">&#xe67f;</i> 后台管理中心 <span class="c-gray en">&gt;</span>日志管理 <span class="c-gray en">&gt;</span> 登录日志  <a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" href="javascript:location.replace(location.href);" title="刷新" ><i class="Hui-iconfont">&#xe68f;</i></a></nav>
<div class="page-container">
<form method="post" name="query_order_form"  id="query_order" action="${contextPath}/user_login_log/index_log" >    
   <input type="hidden" name="page" value="${pagination.pageNo}"  id="page" />                       
    <div class="text-c">
         <table class="table">
                <tr>
                    <td style="text-align: right;">用户名：</td>
                    <td>
                        <input id="username" value="${userLoginLogQo.username}" class="input-text  radius" style="width:250px" placeholder="" name="username" type="text" value=""/>
                    </td>
	            	<td style="text-align: right;">用户登录IP：</td>
                   <td>
                        <input id="loginip"   value="${userLoginLogQo.loginip}"  class="input-text  radius" style="width:250px" placeholder="" name="loginip" type="text" value=""/>
                    </td>
             </tr>
              <tr>     
                    <td style="text-align: right;">登录时间：</td>
                    <td>
                        <input type="text" value="<#if userLoginLogQo.logintimestart?? >${userLoginLogQo.logintimestart?date}</#if>"   onfocus="WdatePicker({ maxDate:'#F{$dp.$D(\'datemax\')||\'%y-%M-%d\'}',readOnly : true })" id="datemin" name="logintimestart" class="input-text Wdate" style="width:120px;" >
                        -
                        <input type="text" value="<#if userLoginLogQo.logintimesend?? >${userLoginLogQo.logintimesend?date}</#if>"  onfocus="WdatePicker({ minDate:'#F{$dp.$D(\'datemin\')}',maxDate:'%y-%M-%d' ,readOnly : true})" id="datemax" name="logintimesend" class="input-text Wdate" style="width:120px;">
                    </td>
                 <td style="text-align: right;">登出时间：</td>
                    <td>
                        <input type="text" value="<#if userLoginLogQo.loginoutstart?? >${userLoginLogQo.loginoutstart?date}</#if>"   onfocus="WdatePicker({ maxDate:'#F{$dp.$D(\'datemax\')||\'%y-%M-%d\'}',readOnly : true })" id="datemins" name="loginoutstart" class="input-text Wdate" style="width:120px;" >
                        -
                        <input type="text" value="<#if userLoginLogQo.loginoutend?? >${userLoginLogQo.loginoutend?date}</#if>"  onfocus="WdatePicker({ minDate:'#F{$dp.$D(\'datemin\')}',maxDate:'%y-%M-%d' ,readOnly : true})" id="datemaxs" name="loginoutend" class="input-text Wdate" style="width:120px;">
                    </td>   
                </tr>
                 
                 <tr>
                 	<td colspan="4" style="text-align: center;">
                 	 <button type="button" class="btn btn-success" onclick="search()" id="" name=""><i class="Hui-iconfont">&#xe665;</i> 查询</button>
           			 <button type="button" class="btn btn-success" id="toIsEmpty" onclick="toEmpty()" name="toIsEmpty"><i class="Hui-iconfont">&#xe665;</i> 重置</button>
                	 </td>
              </tr>
            </table>
           
    </div>
</form>

    <div class="cl pd-5 bg-1 bk-gray mt-20"> 
  
    
    <span class="r">共有数据：<strong> ${pagination.totalCount} </strong> 条</span> </div>
    <table class="table table-border table-bordered table-bg">
        <thead>
         
        <tr   class="text-c">
            <!-- <th width="45px">
            <input  type="checkbox" id="selectAll" disabled="disabled" onclick="checkAll()"/>
            </th> -->
            <th >序号</th>
            <th >登录名</th>
            <th >用户登录ip</th>
            <th >登录时间</th>
            <th >登出时间</th>
            <th >状态</th>
             
        </tr>
        </thead>
        <tbody>
       <#if pagination.list?? && (pagination.list?size &gt; 0) >
        <#list pagination.list as logs> 
        	 <tr class="text-c">
        	   	<td style="width: 10%"> ${(((pagination.pageNo-1)*10)+ logs_index)+1}  </td>
        	   	<td style="width: 10%">${logs.username} </td>
        	   	<td style="width: 10%">${logs.loginip } </td>
        	   <td style="width: 10%"><#if logs.logintime?? >${logs.logintime?datetime}</#if> </td>
        	   <td style="width: 20%"><#if logs.loginout?? >${logs.loginout?datetime}</#if> </td>
        	   <td style="width: 20%">  <#if  logs.type==1 >登陆系统</#if>
										 <#if logs.type==2 >退出系统</#if>
				</td>
        	 </tr>
      </#list></#if>
     </tbody>
    </table>
    <div id="biuuu_city" style="padding-top: 10px;float: right"></div>
</div>
<@frame.end "default">
</@frame.end>

<script type="text/javascript" src="${contextPath}/resources/lib/My97DatePicker/4.8/WdatePicker.js"></script>
<script type="text/javascript" src="${contextPath}/resources/js/laypage/laypage.js"></script>
<script type="text/javascript" src="${contextPath}/resources/js/log/user_login_log.js"></script>
<script type="text/javascript">
var path="${contextPath}";

laypage({
    cont: 'biuuu_city',//容器。值支持id名、原生dom对象，jquery对象。
    pages: ${pagination.totalPage},//通过后台拿到的总页数
    curr:  ${pagination.pageNo} || 1, //当前页
    skip: true, //是否开启跳页
	first: 1, //将首页显示为数字1,。若不显示，设置false即可
	last: ${pagination.totalPage}, //将尾页显示为总页数。若不显示，设置false即可
    jump: function(obj , first){//触发分页后的回调
        if(!first){ //点击跳页触发函数;当前页为obj.curr
          $(page).val(obj.curr);//获取点击的页码
          $(query_order_form).submit();
        }
    }
})  
</script>
</body>

</html>
 
